<div class="container">
    <div class="section" id="mysec">
        <volist name="res" id="vo">
            <div class="row">
                <div class="col s12">
                    <div class="card-panel hoverable">
                        <div class="">
                            <div class="left">
                                <h4>
                                    <a href="{:U('Details/index',array('id'=>$vo['id']))}">
                                        <eq name="vo.enclass" value="1">
                                            【个人】
                                            <else/>
                                            【团体】
                                        </eq>
                                        {$vo.title}
                                    </a>
                                </h4>
                            </div>
                            <div class="right" style="margin-top: 20px;">报名截止时间：<span
                                    class="center-aligne" style="color: red">{:date("Y-m-d",$vo["start"])}~{:date("Y-m-d",$vo["end"])}</span></div>
                            <div class="clearfix"></div>
                        </div>
                        <div class="valign">
                            <p>&emsp;&emsp;
                                {:mb_substr(trim(strip_tags($vo["content"])),0,140,'utf-8')}
                                ……
                            </p>
                        </div>

                        <div class="left" style="color: gray">发布时间：<span
                                class="mui--divider-right">{:date("Y-m-d",$vo["addtime"])}&nbsp;</span>&nbsp;报名人数：<span>{:sumPeo($vo['enid'],$vo['enclass'])}/{$vo.num}</span>&nbsp;负责老师：<span>{$vo.pri}</span>
                        </div>

                        <div class="right">
                            <if condition="sumPeo($vo['enid'],$vo['enclass']) lt $vo['num'] ">
                                <if condition="time() lt ($vo['end']+86400) ">
                                    <eq name="vo.enclass" value="1">
                                        <a class="waves-effect waves-light btn red"
                                           href="{:U('Stuform/oneAdd',array('enid'=>$vo['enid']))}" onclick="if(confirm('确定报名吗?')==false)return false;">报名</a>
                                        <else/>
                                        <a class="waves-effect waves-light btn red"
                                           href="{:U('Stuform/team',array('enid'=>$vo['enid']))}">报名</a>
                                    </eq>
                                    <else/>
                                    <a class="waves-effect waves-light btn disabled red">报名已过期</a>
                                </if>
                                <else/>
                                <a class="waves-effect waves-light btn disabled red">报名已满</a>
                            </if>

                            <a class="waves-effect waves-light btn green"
                               href="{:U('Details/index',array('id'=>$vo['id']))}">查看详情</a>
                        </div>
                        <div class="clearfix"></div>


                    </div>
                </div>
            </div>
        </volist>


        <ul class="pagination center">
            {$page}
        </ul>
    </div>


</div>
